package com.ruoyi.point.service.impl;

import java.util.List;

import com.ruoyi.point.mapper.EquipmentMapper;
import com.ruoyi.point.pojo.Equipment;
import com.ruoyi.point.service.IEquipmentService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * 设备管理Service业务层处理
 *
 * @author ruoyi
 * @date 2024-04-22
 */
@Service
public class EquipmentServiceImpl implements IEquipmentService
{
    @Autowired
    private EquipmentMapper equipmentMapper;

    /**
     * 查询设备管理
     *
     * @param EquipmentId 设备管理主键
     * @return 设备管理
     */
    @Override
    public Equipment selectEquipmentByEquipmentId(Long EquipmentId)
    {
        return equipmentMapper.selectEquipmentByEquipmentId(EquipmentId);
    }

    /**
     * 查询设备管理列表
     *
     * @param equipment 设备管理
     * @return 设备管理
     */
    @Override
    public List<Equipment> selectEquipmentList(Equipment equipment)
    {
        return equipmentMapper.selectEquipmentList(equipment);
    }

    /**
     * 新增设备管理
     *
     * @param equipment 设备管理
     * @return 结果
     */
    @Override
    public int insertEquipment(Equipment equipment)
    {
        return equipmentMapper.insertEquipment(equipment);
    }

    /**
     * 修改设备管理
     *
     * @param equipment 设备管理
     * @return 结果
     */
    @Override
    public int updateEquipment(Equipment equipment)
    {
        return equipmentMapper.updateEquipment(equipment);
    }

    /**
     * 批量删除设备管理
     *
     * @param EquipmentIds 需要删除的设备管理主键
     * @return 结果
     */
    @Override
    public int deleteEquipmentByEquipmentIds(Long[] EquipmentIds)
    {
        return equipmentMapper.deleteEquipmentByEquipmentIds(EquipmentIds);
    }

    /**
     * 删除设备管理信息
     *
     * @param EquipmentId 设备管理主键
     * @return 结果
     */
    @Override
    public int deleteEquipmentByEquipmentId(Long EquipmentId)
    {
        return equipmentMapper.deleteEquipmentByEquipmentId(EquipmentId);
    }
}
